import request from '@/utils/request'

// 查询车辆类型收费标准列表
export function listTrailer(query) {
  return request({
    url: '/api/driver/trailer/list',
    method: 'get',
    params: query
  })
}

export function queryPlatformTrailerType(query) {
  return request({
    url: "/api/trailer/type/queryPlatformTrailerType",
    method: "post",
    data: query,
  });
}


export function listPlateType(data) {
  return request({
    url: "/system/price/list",
    method: "get",
    params: data,
  });
}

// 查询车辆类型收费标准详细
export function getTrailer(id) {
  return request({
    url: '/api/driver/trailer/' + id,
    method: 'get'
  })
}

export function getType(id) {
  return request({
    url: "/system/price/" + id,
    method: "get",
  });
}

// 新增车辆类型收费标准
export function addTrailer(data) {
  return request({
    url: "/system/price",
    method: "post",
    data: data,
  });
}

export function addType(data) {
  return request({
    url: "/system/price",
    method: "post",
    data: data,
  });
}
// 

// 修改车辆类型收费标准
export function updateTrailer(data) {
  return request({
    url: "/system/price",
    method: "put",
    data: data,
  });
}

// 删除车辆类型收费标准
export function delTrailer(id) {
  return request({
    url: '/api/trailer/type/' + id,
    method: 'delete'
  })
}
